﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<PresentationLayerMVC.Controllers.BookingController+SearchModel>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
	View Booking
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
<link rel="stylesheet" href="http://code.jquery.com/ui/1.10.3/themes/smoothness/jquery-ui.css" />
  <script src="http://code.jquery.com/jquery-1.9.1.js"></script>
  <script src="http://code.jquery.com/ui/1.10.3/jquery-ui.js"></script>
  <script type="text/javascript">

      $(function () {
          $("#StartDate").datepicker();
          $("#EndDate").datepicker();
      });
  </script>
    <h2>View Booking</h2>
         <%using (Html.BeginForm()){ %>
       <fieldset>
        <%= Html.LabelFor(s => s.StartDate)   %>
     
        <%= Html.TextBoxFor(s => s.StartDate)   %>
        
        <%= Html.LabelFor(s => s.EndDate)   %>
     
        <%= Html.TextBoxFor(s => s.EndDate)   %>
        <%= Html.LabelFor(s => s.GuestName)   %>
     
        <%= Html.TextBoxFor(s => s.GuestName)%>

        <br />
        
        <%--  <% foreach (var s in ViewData.Model.RoomTypeModels) { %>
          <input type="checkbox" name="SelectedObjects" value="<%= s.Id%>" /> 
                <%= Html.Encode(s.Name)%>
    
         <%}%>--%>
         
          <p>
            <input type="submit" name="SearchButton" value="Search" />
        </p>
       </fieldset>
      <div id="ViewBookingResult">
            <%if (Model.Result != null && Model.Result.Count()>0)
              {
                  Html.RenderPartial("ViewBookingResult", Model.Result);
              }%>
        </div>
	 <%} %>
</asp:Content>
